import Vue from 'vue'
import Vuex from 'vuex'
import VuexPersiostence from 'vuex-persist'

import {user} from "@/store/module/user"
import {router} from "@store/module/router"
import {dictionary} from "@store/module/dictionary"

Vue.use(Vuex)

const vuexLocal = new VuexPersiostence({
    storage:window.localStorage,
    modules:['user']
})
export const store = new Vuex.store({
    modules:{
        user,
        router,
        dictionary
    },
    plugins:[vuexLocal.plugins]
})